﻿@model SuperiorModel.TPagedModelList<SuperiorModel.CouponModel>
<table class="layui-table" id="AppList" lay-filter="test">
    <thead>
        <tr>
            <th>优惠券ID</th>
            <th>优惠券名称</th>
            <th>所属商户账号</th>
            <th>优惠券类型</th>
            <th>最低消费金额</th>
            <th>优惠方式</th>
            <th>有效期</th>
            <th>发放总数量</th>
            <th>已领取数量</th>
            <th>添加时间</th>
        </tr>
    </thead>
    <tbody>
        @foreach (var item in Model.TList)
        {
            <tr>
                <td>@item.Id</td>
                <td>@item.CouponName</td>
                <td>@item.LoginName</td>
                <td>
                    @switch (item.CouponType)
                    {
                        case 1:
                            <span style="color:green">满减券</span>
                            break;
                        case 2:
                            <span style="color:green">折扣券</span>
                            break;
                    }
                </td>
                <td>@item.MinOrderAmount</td>
                <td>

                    @switch (item.CouponType)
                    {
                        case 1:
                            <span>立减@(item.DelAmount)元</span>
                            break;
                        case 2:
                            <span>@(item.Discount)折</span>
                            break;
                    }
                </td>

                <td>@(item.Days)天</td>
                <td>@item.TotalCount</td>
                <td>@item.GetCount</td>
                <td>@item.CreateTime</td>
            </tr>
        }
    </tbody>
</table>
@Html.Partial("_TPager", Model.PagingResult)    